// import QtQuick 1.0 // to target S60 5th Edition or Maemo 5
import QtQuick 1.1
import com.nokia.meego 1.0
import "js/core.js" as Core
import "parts/"

PageStackWindow {
    id: appWindow    
    initialPage: mainPage

    Page {
        id: mainPage
        orientationLock: PageOrientation.LockPortrait

        Image{
            anchors.fill: parent
            source: "qrc:/violet/splash"
        }

        MouseArea{
            id: mousearea1
            anchors.fill: parent
            onClicked: {
                splashTimer.stop();
                pageStack.push(Qt.resolvedUrl("pages/PersonPage.qml"));
            }
        }


        Timer {
            id: splashTimer
            interval: 1000; repeat: false
            onTriggered: {
                pageStack.push(Qt.resolvedUrl("pages/PersonPage.qml"))
            }
        }
    }

    ToolBar {
        id: sharedToolBar
        anchors {
            left: parent.left
            right: parent.right
            bottom: parent.bottom
        }
    }

    Component.onCompleted:
    {
        Core.openDB();
        splashTimer.start()
    }
}
